package com.iceland.common.message;

public class MessageFactory {

    /**
     * 请求将该通道设置为数据交换通道
     * @return
     */
    public static CmdMessage dataExchangeChannelConnectMessage(String proxyServerAddress){
        CmdMessage message=new CmdMessage(MessageType.DATA_EXAHCNAGE_CHANNEL_CONNECT.getType());
        message.putHeader(HeaderType.PROXY_SERVER_ADDRESS,proxyServerAddress);
        return message;
    }
    /**
     * 请求将该通道设置为命令通道
     * @return
     */
    public static CmdMessage cmdChannelConnectMessage(String cmdServerAddress){
        CmdMessage message=new CmdMessage(MessageType.CMD_CHANNEL_CONNECT.getType());
        return message;
    }

    /**
     * 请求为该通道绑定一个连接真实服务器的可用通道
     * @return
     */
    public static CmdMessage connectRealServerChannelMessage(){
        CmdMessage message=new CmdMessage(MessageType.BIND_REAL_SERVER_CHANNEL.getType());
        return message;
    }


}
